﻿using Comain.RBAC;
using Common;
using IService.Rempos;

namespace IService
{
    public interface IMemberService
    {
        /// <summary>
        /// 会员等级增加
        /// </summary>
        /// <param name="t">会员等级实体</param>
        /// <returns>受影响的行数</returns>
        Task<int> AddMemberLevel(T_MemberLevel t);
        /// <summary>
        /// 会员等级列表
        /// </summary>
        /// <returns>返回会员等级列表</returns>
        Task<List<T_MemberLevel>> GetMemberList();
        /// <summary>
        /// 会员增加
        /// </summary>
        /// <param name="t">会员实体</param>
        /// <returns>受影响的行数</returns>
        Task<int> AddMember(T_Member t, IList<int> ints);
        /// <summary>
        /// 获取会员列表
        /// </summary>
        /// <param name="userName">会员名称</param>
        /// <param name="tel">手机号</param>
        /// <param name="levelId">等级id</param>
        /// <returns>会员列表</returns>
        
        /// <summary>
        /// 删除会员 单个删除
        /// </summary>
        /// <param name="id">会员id</param>
        /// <returns>受影响的行数</returns>
        Task<int> DelMemberItem(Guid id);
        /// <summary>
        /// 会员的返填
        /// </summary>
        /// <param name="id">会员id</param>
        /// <returns>返回会员的实体</returns>
        
        /// <summary>
        /// 确定修改会员
        /// </summary>
        /// <param name="t">会员实体</param>
        /// <returns>受影响的行数</returns>
        Task<int> UpdateMember(T_Member t);

        /// <summary>
        /// 登录
        /// </summary>
        /// <param name="pwd"></param>
        /// <returns></returns>
        Task<LoginCommon<T_Member>> GetUsers(string? name,string pwd);









        /// <summary>
        /// 显示权限信息
        /// </summary>
        /// <returns></returns>
        List<TreeItem> ShowPerission(int perentId);
        /// <summary>
        /// 添加
        /// </summary>
        /// <param name="info"></param>
        /// <param name="perLists"></param>
        /// <returns></returns>
        Task<int> AddRolePermission(T_Role info, IList<int> perLists);
        /// <summary>
        /// 显示+分页+查询
        /// </summary>
        /// <param name="index"></param>
        /// <param name="page"></param>
        /// <param name="name"></param>
        /// <returns></returns>
        Task<PageComm<List<RolePerissionDTO>>> Show(int index, int page, string? name);
    }
}
